package com.example.concurrentprogramming8016.future.forkjoin;

import java.util.Random;

/**
 * @author liyanhao
 * @Date 2023-01-08 0:18
 */
public class ArrayUtils {
    public static int[] buildRandomIntArray(int size){
        int[] arrayToCalculateSumOf = new int[size];
        Random generator = new Random();
        for (int i = 0; i < arrayToCalculateSumOf.length; i++) {
            arrayToCalculateSumOf[i] = generator.nextInt(1000);
        }
        return arrayToCalculateSumOf;
    }
}
